{%- if include.collection.size > 0 -%}
  <ul>
    {%- for subitem in include.collection -%}
    <li>
      {%- if subitem.spacer %}
        <hr />
      {%- elsif subitem.include_versioned_children_here %}
        TODO
      {%- elsif subitem.url %}
        <a class="nav-link{% if subitem.url == page.url %} is-active{% endif %}" href="{{ subitem.url | relative_url }}">
          {{ subitem.title | escape }}
        </a>
      {%- else %}
        <span class="section-title">{{ subitem.title | escape }}</span>
      {%- endif %}
      {%- if subitem.children.size > 0 %}
	{%- if page.url contains subitem.url or include.expand %}
          {% include nav-level.html collection=subitem.children expand=true %}
	{%- endif %}
      {%- endif %}
    </li>
    {%- endfor %}
  </ul>
{%- endif %}
